
TOP_DIR := .
sinclude $(TOP_DIR)/tools/w806/conf.mk

ifndef PDIR # {
GEN_IMAGES= $(TARGET).elf
GEN_BINS = $(TARGET).bin
SUBDIRS = \
    $(TOP_DIR)/app \
    $(TOP_DIR)/demo 
endif # } PDIR

ifndef PDIR # {
ifeq ($(USE_LIB), 0)
SUBDIRS += \
    $(TOP_DIR)/platform/arch        \
    $(TOP_DIR)/platform/drivers    
endif
endif

COMPONENTS_$(TARGET) =	\
    $(TOP_DIR)/app/libappuser$(LIB_EXT)     \
    $(TOP_DIR)/demo/libdemo$(LIB_EXT)    

ifeq ($(USE_LIB), 0)
COMPONENTS_$(TARGET) += \
    $(TOP_DIR)/platform/boot/libwmarch$(LIB_EXT)        \
    $(TOP_DIR)/platform/drivers/libdrivers$(LIB_EXT)  
endif


LINKLIB = 	\
    $(TOP_DIR)/lib/$(CONFIG_ARCH_TYPE)/libdsp$(LIB_EXT)	


LINKFLAGS_$(TARGET) =  \
	$(LINKLIB)

CONFIGURATION_DEFINES =	

DEFINES +=				\
	$(CONFIGURATION_DEFINES)

DDEFINES +=				\
	$(CONFIGURATION_DEFINES)

INCLUDES := $(INCLUDES) -I$(PDIR)include
INCLUDES += -I ./

sinclude $(TOP_DIR)/tools/$(CONFIG_ARCH_TYPE)/rules.mk

.PHONY: FORCE
FORCE:
    # @echo $(subst ee,EE,"feet on the street")
    # # @echo $(bb)
    # # echo aa
    # $(info $(aa))
    

    # aa := $(subst ee,EE,feet on the street)  # subst函数的作用是在参数3中的字符串1（参数1）被字符串2（参数2）替换。
    # bb := 123
    # $(info info text)               # makefile中显示信息可以用 $(info XXXXXX), XXXXXX就是要显示的信息
    # $(warning warn text)            # makefile中用warning可以显示带行号的信息，可以用$(warning YYYYYYY)  YYYYYYY是要显示的信息，显示完后不停止make的执行
    # $(error error text)             # makefile中用warning可以显示带行号的信息，可以用$(error ZZZZZZ)  ZZZZZZ是要显示的信息，显示完后将停止make的执行，即时停止
    # $(warning $(aa))                # $(warning YYYYYYY)用变量$(aa)代替
    # $(error $(aa))                  # $(error ZZZZZZ) 用变量$(aa)代替
    # $(info $(bb))                   # $(info XXXXXX)  用变量$(bb)代替